<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="../header.jsp" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page import ="java.util.*" %>
<%
	List data = (List)request.getAttribute("list");
%>

<div style="text-align: center">
		<ul id="admin_tab">
				<li id="admin_tab_1" class="on"><a href="<%=path%>/admin/index.jsp"><strong>관리자 메인</strong></a></li>
				<li id="admin_tab_2" class=""><a href="<%=path%>/admin_room.admin"><strong>객실 관리</strong></a></li>
				<li id="admin_tab_3" class=""><a href="<%=path%>/reservation.admin"><strong>예약 관리</strong></a></li>
				<li id="admin_tab_4" class=""><a href="<%=path%>/boardAdmin.admin"><strong>게시판 관리</strong></a></li>
		</ul>
</div>

					
<div class="ad_box mgT30" id="report_summary">

<table cellspacing="0" class="type_D" width="990">			
	<colgroup>
		<col width="20">
		<col width="">
		<col width="20">
	</colgroup>
	<tbody align="center">
		<tr>
			<td height="80"></td>
			<td>
				<table cellspacing="0" class="type_T" width="900">
					<colgroup>
						<col width="">
						<col width="120">
						<col width="120">
						<col width="120">
						<col width="120">
					</colgroup>
					<tbody align="center" >
						<tr id="price_tab">
							<td height="30" align="left" class="non" style="font: bold 15px/15px Dotum,sans-serif;color: #494840;">REPORT SUMMARY</td>
							<td class="on" id="price_tab_1"><a href="javascript:displaytype(1,4,'price_tab','price_box');" style="padding: 10px 30px;">오늘</a></td>
							<td class="off" id="price_tab_2"><a href="javascript:displaytype(2,4,'price_tab','price_box');" style="padding: 10px 30px;">어제</a></td>
							<td class="off" id="price_tab_3"><a href="javascript:displaytype(3,4,'price_tab','price_box');" style="padding: 10px 30px;">최근 7일</a></td>
							<td class="off" id="price_tab_4"><a href="javascript:displaytype(4,4,'price_tab','price_box');" style="padding: 10px 20px;">최근 30일</a></td>
						</tr>
					</tbody>
				</table>
			</td>
			<td></td>
		</tr>
		<tr>
			<td></td>
			<td id="price_box_1" style="display: block;">
				<table cellspacing="0" class="type_D2" width="900">
					<colgroup>
						<col width="170">
						<%for(int i=0; i <= data.size() ; i++){ %>
						<col width="120">
						<%-- <col width="120">
						<col width="120">
						<col width="120">
						<col width="120">
						<col width="120"> --%>
						<% } %>
						<col width="150">
					</colgroup>
					<tbody>
						<tr>
							<td align="left" height="40" class="bdTnon" width="150px" style="width: 150px">메인 방문 수</td>
							<c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
							</c:forEach>
							
							<td align="right" class="bdTnon">객실 예약 수</td>
						</tr>
						<tr>
							<c:forEach var="Today" items="${Today}">
							<td height="30" align="left" class="bdBt"><strong class="txC_333">${Today.COUNT}회</strong></td>
							<!-- <td class="bdBt"><strong class="txC_333">210회</strong></td>
							<td class="bdBt"><strong class="txC_333">130회</strong></td>
							<td class="bdBt"><strong class="txC_333">170회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td> -->
							</c:forEach>
							<td align="right" class="bdBt"><strong class="txC_blue3">13</strong>회</td>
						</tr>
					</tbody>
				</table>
				<p class="ad_data">
					<span class="txC_gre3">집계 기간</span>  
					2014/04/29
					~
					2014/04/29
				</p>
			</td>
			
			
			
			<td id="price_box_2" style="display: none;">
				<table cellspacing="0" class="type_D2" width="900">
					<colgroup>
						<col width="170">
						<%for(int i=0; i <= data.size() ; i++){ %>
						<col width="120">
						<%-- <col width="120">
						<col width="120">
						<col width="120">
						<col width="120">
						<col width="120"> --%>
						<% } %>
						<col width="150">
					</colgroup>
					<tbody>
						<tr>
							<td align="left" height="40" class="bdTnon" width="150px" style="width: 150px">메인 방문 수</td>
							<c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
							</c:forEach>
							
							<td align="right" class="bdTnon">객실 예약 수</td>
						</tr>
						<tr>
							<c:forEach var="Yester" items="${Yester}">
							<td height="30" align="left" class="bdBt"><strong class="txC_333">${Yester.COUNT}회</strong></td>
							<!-- <td class="bdBt"><strong class="txC_333">210회</strong></td>
							<td class="bdBt"><strong class="txC_333">130회</strong></td>
							<td class="bdBt"><strong class="txC_333">170회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td> -->
							</c:forEach>
							<td align="right" class="bdBt"><strong class="txC_blue3">13</strong>회</td>
						</tr>
					</tbody>
				</table>
				<p class="ad_data">
					<span class="txC_gre3">집계 기간</span>  
					2014/04/28
					~
					2014/04/28
				</p>
			</td>
			
			
			
			
			<td id="price_box_3" style="display: none;">
				<table cellspacing="0" class="type_D2" width="900">
					<colgroup>
						<col width="170">
						<%for(int i=0; i <= data.size() ; i++){ %>
						<col width="120">
						<%-- <col width="120">
						<col width="120">
						<col width="120">
						<col width="120">
						<col width="120"> --%>
						<% } %>
						<col width="150">
					</colgroup>
					<tbody>
						<tr>
							<td align="left" height="40" class="bdTnon" width="150px" style="width: 150px">메인 방문 수</td>
							<c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
							</c:forEach>
							
							<td align="right" class="bdTnon">객실 예약 수</td>
						</tr>
						<tr>
							<c:forEach var="Week" items="${Week}">
							<td height="30" align="left" class="bdBt"><strong class="txC_333">${Week.COUNT}회</strong></td>
							<!-- <td class="bdBt"><strong class="txC_333">210회</strong></td>
							<td class="bdBt"><strong class="txC_333">130회</strong></td>
							<td class="bdBt"><strong class="txC_333">170회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td> -->
							</c:forEach>
							<td align="right" class="bdBt"><strong class="txC_blue3">13</strong>회</td>
						</tr>
					</tbody>
				</table>
				<p class="ad_data">
					<span class="txC_gre3">집계 기간</span>  
					2014/04/22
					~
					2014/04/29
				</p>
			</td>
			
			
			
			
			
			<td id="price_box_4" style="display: none;">
				<table cellspacing="0" class="type_D2" width="900">
					<colgroup>
						<col width="170">
						<%for(int i=0; i <= data.size() ; i++){ %>
						<col width="120">
						<%-- <col width="120">
						<col width="120">
						<col width="120">
						<col width="120">
						<col width="120"> --%>
						<% } %>
						<col width="150">
					</colgroup>
					<tbody>
						<tr>
							<td align="left" height="40" class="bdTnon" width="150px" style="width: 150px">메인 방문 수</td>
							<c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
							</c:forEach>
							
							<td align="right" class="bdTnon">객실 예약 수</td>
						</tr>
						<tr>
							<c:forEach var="Month" items="${Month}">
							<td height="30" align="left" class="bdBt"><strong class="txC_333">${Month.COUNT}회</strong></td>
							<!-- <td class="bdBt"><strong class="txC_333">210회</strong></td>
							<td class="bdBt"><strong class="txC_333">130회</strong></td>
							<td class="bdBt"><strong class="txC_333">170회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td>
							<td class="bdBt"><strong class="txC_333">180회</strong></td> -->
							</c:forEach>
							<td align="right" class="bdBt"><strong class="txC_blue3">13</strong>회</td>
						</tr>
					</tbody>
				</table>
				<p class="ad_data">
					<span class="txC_gre3">집계 기간</span>  
					2014/04/01
					~
					2014/04/29
				</p>
			</td>
			
			
			
			
			<td></td>
		</tr>
		<tr>
			<td height="20" colspan="3"></td>
		</tr>
	</tbody>
</table>
</div>

<br><br>




<div id="report">
	<span class="title">RESERVATION REPORT</span>
	<table class="tb_report" cellpadding="0" cellspacing="0" border="0" width="100%" summary="카운팅">
                <colgroup>
                  <col width="10%">
                  <col width="15%">
                  <col width="10%">
                  <col width="10%">
                  <col width="10%">
                  <col width="15%">
                  <col width="10%">
                  <col width="10%">
                </colgroup>
                <thead>
                  <tr>
                 	<td rowspan="2" style="border-left: 1px solid #b4b2a4;">날짜</td>
                    <td rowspan="2">총 예약 수</td>
                    <td colspan="6" style="border-right: 1px solid #b4b2a4;">객실별 예약현황</td>
                  </tr>
                  <tr>
                    <c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
					</c:forEach>
                  </tr>
                </thead>
                <tbody>
                  <tr>
                    <td>2013/04/02</td>
                    <td>5회</td>
                    <td>O</td>
                    <td>X</td>
                    <td>O</td>
                    <td>O</td>
                    <td>O</td>			
                    <td class="last">O</td>
                  </tr>
                </tbody>
              </table>
              <br><br><br>
</div>





<div id="report">
	<span class="title">CONNECT REPORT</span>
	<table class="tb_report" cellpadding="0" cellspacing="0" border="0" width="100%" summary="카운팅">
                <colgroup>
                  <col width="10%">
                  <col width="15%">
                  <col width="10%">
                  <col width="10%">
                  <col width="10%">
                  <col width="15%">
                  <col width="10%">
                  <col width="10%">
                </colgroup>
                <thead>
                  <tr>
                 	<td rowspan="2" style="border-left: 1px solid #b4b2a4;">날짜</td>
                    <td rowspan="2">메인 접속자 수</td>
                    <td colspan="6" style="border-right: 1px solid #b4b2a4;">객실별 클릭 수</td>
                  </tr>
                  <tr>
                 	 <c:forEach var="room" items="${list}">
							<td class="bdTnon">${room.R_NAME}</td>
							<!-- <td class="bdTnon">베이직룸</td>
							<td class="bdTnon">빈티지룸</td>
							<td class="bdTnon">컬러풀룸</td>
							<td class="bdTnon">러블리룸</td>
							<td class="bdTnon">로맨틱빈티지룸</td> -->
					</c:forEach>
                  </tr>
                </thead>
                <tbody>
                  
                  <c:forEach var="Count" begin="0" items="${Count}" varStatus="Status">
                  	
                  	<c:choose>
					<c:when test="${Status.first}"><tr><td style="border-left: 1px solid #b4b2a4;">${Count.V_DATE}</td><td>${Count.COUNT} 회</td></c:when>
					<c:when test="${Status.last}"><td>${Count.COUNT} 회</td></tr></c:when>
					<c:when test="${Status.count%7 == '0'}"><td>${Count.COUNT} 회</td></tr></c:when>
					<c:when test="${(Status.count-1)%7 == '0'}"><tr><td style="border-left: 1px solid #b4b2a4;">${Count.V_DATE}</td><td>${Count.COUNT} 회</td></c:when>
					<c:otherwise><td><c:out value="${Count.COUNT}"/> 회</td></c:otherwise>
					</c:choose>
                  	
<%--                <c:if test="${(Status.count%8) != '0'}"></c:if> --%>
                  	
                    <!-- <td>310회</td>
                    <td>401회</td>
                    <td>330회</td>
                    <td>180회</td>			
                    <td class="last">52회</td> -->
                  </c:forEach>
                  
                </tbody>
              </table>
              <br><br><br><br>
</div>



<%@include file="../footer.jsp" %>